using System;
using System.Collections.Generic;
using System.Text;
using QLPMT_DTO;
using QLPMT_DAO;

namespace QLPMT_BUS
{
   public class ChiTietBaoCaoDoanhThuBUS
    {
       public string GetMa()
       {
           List<ChiTietBaoCaoDoanhThu> list = new List<ChiTietBaoCaoDoanhThu>();
           list = new ChiTietBaoCaoDoanhThuDAO().GetAll();
           ChiTietBaoCaoDoanhThu temp = new ChiTietBaoCaoDoanhThu();
           foreach (ChiTietBaoCaoDoanhThu X in list)
           {
               temp.MaChiTiet= X.MaChiTiet;
           }
           string ma = "";
           if (temp.MaChiTiet != null)
           {
               
               int sobenhnhan = int.Parse(temp.MaChiTiet) + 1;
               ma = sobenhnhan.ToString();
           }
           else
               ma = "1";
           return ma;
       }
       // 
       public List<ChiTietBaoCaoDoanhThu> DoanhThuBaoCaoTheoNgay(int thang)
       {
           return new ChiTietBaoCaoDoanhThuDAO().DoanhThuTheoNgay(thang);
       }
    }
}
